package com.woniuxy.commons.entity;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
@author zouyang
@date 2020/8/3 - 20:25
*/
@Data
@AllArgsConstructor
@NoArgsConstructor
public class ExamType implements Serializable {
    /**
    * 考试id
    */
    private Integer id;

    /**
    * 考试分类名称
    */
    private String label;

    /**
    * 考试父分类
    */
    private Integer pid;

    private transient List<ExamType> children = new ArrayList<>();

    private static final long serialVersionUID = 1L;

    public void add(ExamType examType){
        children.add(examType);
    }
}